﻿using Application.Auth.Command.Login;
using Application.Auth.Interfaces.Repositories;
using MediatR;

namespace Application.Auth.Command
{
    //public class AuthenticationUserHandle : IRequestHandler<AuthenticateUserCommand, AuthenticateUserResult>
    //{
    //    private readonly IAuthenticateUserRepository _repository;
    //    public AuthenticationUserHandle(IAuthenticateUserRepository repository)
    //    {
    //        _repository = repository;
    //    }
    //    public async Task<AuthenticateUserResult> Handle(AuthenticateUserCommand request, CancellationToken cancellationToken)
    //    {
    //        var result = await _repository.GetUserCredentialByPhoneNumberAsync(request.PhoneNumber) 
    //            ?? throw new Exception("todo");

    //        return result;
    //    }
    //}
}
